package Controller;

import javax.swing.JFrame;
import javax.swing.JPanel;

import GUI.FrameIS;
import GUI.ISMainGui;
import GUI.InformationStationOneTimeCostumerOrderGui;
import GUI.InformationStationOrderCheckInGui;
import GUI.InformationStationSubscriptionGui;
import GUI.MainGui;
import GUI.SubscriptionOrderGui;

/**
 * this is a controller of the information station. it will use the check in orders.
 * @author Or Marx
 *
 */
public class InformationStation {

	/**
	 * will run the GUI of the subscription check in.
	 */
	public void subscriptionCheckIn() 
	{
		JFrame frame=FrameIS.getFrame();
		InformationStationSubscriptionGui isGui=new InformationStationSubscriptionGui();
		isGui.setLastPanel((JPanel)frame.getContentPane());
		isGui.setFrame(frame);
		frame.setContentPane(isGui);
		frame.setVisible(true);
		
	}
	/**
	 * will run the GUI of the order check in.
	 */
	public void orderCheckIn() 
	{
		JFrame frame=FrameIS.getFrame();
		InformationStationOrderCheckInGui isGui=new InformationStationOrderCheckInGui();
		isGui.setLastPanel((JPanel)frame.getContentPane());
		isGui.setFrame(frame);
		frame.setContentPane(isGui);
		frame.setVisible(true);
		
	}

	/**
	 * will run the GUI of the customer one time order.
	 */
	public void oneTimeCostumerOrder() 
	{
		JFrame frame=FrameIS.getFrame();
		InformationStationOneTimeCostumerOrderGui isGui=new InformationStationOneTimeCostumerOrderGui();
		isGui.setLastPanel((JPanel)frame.getContentPane());
		isGui.setFrame(frame);
		frame.setContentPane(isGui);
		frame.setVisible(true);
		
	}
}
